﻿using System;
using System.Collections.Generic;
using System.ServiceModel;
using System.Runtime.Serialization;

namespace StockTrader.BusinessService.DataContract
{    
    [DataContract()]
    public class OrdersDataModel
    {
        [DataMember]
        public int OrderId { set; get; }
        [DataMember]
        public string AccountNo { set; get; }
        [DataMember]
        public string OrderSide { set; get; }
        [DataMember]
        public string Symbol { set; get; }
        [DataMember]
        public DateTime OpenDate { set; get; }
        [DataMember]
        public DateTime ExpireDate { set; get; }
        [DataMember]
        public DateTime TimeStamp { set; get; }
        [DataMember]
        public string OrderSpec { set; get; }
        [DataMember]
        public string OrderClass { set; get; }
        [DataMember]
        public string OrderMode { set; get; }
        [DataMember]
        public List<OrdersPlacedData> OrderPlaced { set; get; }

        public OrdersDataModel() { }
        public OrdersDataModel(int orderid, string acc, string side, string sym, DateTime open, DateTime expr, string spec, string clas, string mode, List<OrdersPlacedData> ordersplaced)
        {
            OrderId = orderid;
            AccountNo = acc;
            OrderSide = side;
            Symbol = sym;
            OpenDate = open;
            ExpireDate = expr;
            OrderSpec = spec;
            OrderClass = clas;
            OrderMode = mode;
            OrderPlaced = ordersplaced;
        }
    }
}
